import { createApp } from 'vue'
import { router } from '@/core/router/index'

import App from './App.vue'
import '@/assets/styles/reset.less'
import ElementPlus from 'element-plus'
import * as ElementPlusIconsVue from '@element-plus/icons-vue'
import 'element-plus/dist/index.css'
import 'virtual:windi.css'
import 'nprogress/nprogress.css'
import '@/core/router/permission'

import store from '@/core/stores/index'

const app = createApp(App)
app.use(ElementPlus)
app.use(store)
app.use(router)
import permistion from '@/core/directives'
app.use(permistion)
for (const [key, component] of Object.entries(ElementPlusIconsVue)) {
  app.component(key, component)
}

app.mount('#app')
